
function forget() {
    var email = $("#your-email").val();
    $.post(
        CONTEXT_PATH + "/user/sendcode",
        {"email":email},
        function(data) {
            data = $.parseJSON(data);
            if (data.code == 0) {
                // 成功
                $("#getKaptchaBtn").text("已发送");
            } else {
                if (data.emailMsg != null) {
                    alert(data.emailMsg);
                }
                if (data.kaptchaMsg != null) {
                    alert(data.kaptchaMsg);
                }
            }
        }
    );
}